﻿using System;
using System.Linq;

namespace BarManager.Core.DomainModel
{
    public interface IObjectContext
    {
        IQueryable<TEntity> Query<TEntity>() where TEntity : class;
        TEntity Create<TEntity>() where TEntity : class;
        void Add<TEntity>(TEntity entity) where TEntity : class;
        void Update<TEntity>(TEntity entity) where TEntity : class;
        void Delete<TEntity>(TEntity id) where TEntity : class;        
    }
}
